Skip to content

Conversation

JarmouniA
Copy link

Following the introduction of stm32h750b-dk 'ext_flash_app' board variant (zephyrproject-rtos/zephyr#97037), for storing apps in external Flash and chainloading them with MCUboot that's placed in internal Flash, we need a DT overlay to designate internal Flash & controller as the chosen 'zephyr,flash' & 'zephyr,flash-controller' for the MCUboot Zephyr Application. This way, no DT overlay will be needed at the Zephyr user app level.

Also, remove board conf file, as enabling STM32_MEMMAP is no longer needed here since it is now set on the Zephyr side in the board's 'Kconfig.defconfig' when building MCUboot app. And BOOT_MAX_IMG_SECTORS_AUTO no longer need to be disabled, after including the 'soc-nv-flash' binding in the 'st,stm32-qspi-nor' binding, then adding the 'erase-block-size' & 'write-block-size' properties in external Flash DT node.

…rlay

Following the introduction of stm32h750b-dk 'ext_flash_app' board variant,
for storing apps in external Flash and chainloading them with MCUboot that's
placed in internal Flash,
we need a DT overlay to designate internal Flash & controller as the chosen
'zephyr,flash' & 'zephyr,flash-controller' for the MCUboot Zephyr Application.

Signed-off-by: Abderrahmane JARMOUNI <[email protected]>
STM32_MEMMAP is no longer needed since it is now set on the Zephyr side
in the board's 'Kconfig.defconfig' when building MCUboot app.

Also, BOOT_MAX_IMG_SECTORS_AUTO no longer need to be disabled after
including the 'soc-nv-flash' binding in the 'st,stm32-qspi-nor' binding,
then adding the 'erase-block-size' & 'write-block-size' properties
in external Flash DT node.

Signed-off-by: Abderrahmane JARMOUNI <[email protected]>
@JarmouniA
Copy link
Author

Cc @erwango @FRASTM

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder why this has to be applied to a stm32h750b_dk/stm32h750xx/ext_flash_app target.
My understanding of zephyrproject-rtos/zephyr#97037, is that stm32h750b_dk/stm32h750xx is the target running on internal flash.

This way, we re-use zephyr,flash and zephyr,flash-controller, which are already defined for stm32h750b_dk.dts. And since zephyr,code-partition = &boot_partition; is already defined in app.overlay we don't have any dependency on MCUBoot anymore

Copy link
Author

@JarmouniA JarmouniA Oct 7, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The memory layout for running a user app from external Flash is in ext_flash_app variant dts, and we use stm32h750b_dk/stm32h750xx/ext_flash_app target when building with sysbuild.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants